<ion-header>
    <header-component>
        <ion-toolbar>
            <button class="button-left button-clear" (click)="scan()">
            <span class="button-inner">
                <img src="assets/imgs/scan.svg">
            </span>
        </button>
            <button class="button-search button-clear" (click)="Search('0')">
            <span class="button-inner">
                <img src="assets/imgs/search.svg" alt="">
            </span>
        </button>
        </ion-toolbar>
    </header-component>
</ion-header>

<ion-content (ionScroll)="logScrolling($event)" scroll-events="true">
    <div class="bg-top" [ngStyle]="person.headStylebg">
    </div>
    <div class="top">
        <!-- 头像 -->
        <div class="circle text-center">
            <div class='head-portrait' [ngStyle]="person.headStyle"></div>
        </div>

        <!-- 参数项 -->
        <div style="position: relative">
            <span class="bg-shadow" [ngStyle]="person.headStylebg"></span>
            <span class="bg-shadow" [ngStyle]="person.headStylebg"></span>
            <div class="midDiv">
                <div class="mid-content" *ngFor="let data of indexDataList" [ngStyle]="{display: data.isShow? 'block': 'none'}">
                    <!-- <img src="assets/imgs/gallery/SVG/17148.svg"> -->
                    <div class="mid-title">
                        <span class="inline-data" [class.alarm-data]="(data.IndexName === '传感器' && ( data.Data2 !=null ) && ( data.Data1 > 0 ))  || (data.IndexName === '数据栈' && (data.Data2 != null) && (data.Data1 > 0))">
                            {{ data.Data1 | numberAbs:data.Flag }}
                            <i>{{ data.Unit1 }}</i>
                        </span>
                        <span class="total-data" *ngIf='data.Data2'>{{ data.Data2 }}
                            <i>{{ data.Unit }}</i>
                        </span>
                    </div>
                    <div class="mid-name">
                        {{ data.IndexName }}
                    </div>
                </div>
            </div>
        </div>

        <!-- 通知 -->
        <div class='inform' *ngIf='blocInfo && blocInfo.Announcement && blocInfo.Announcement.length'>
            <img src="assets/imgs/gallery/SVG/17124.svg">
            <marquee direction="left">{{ blocInfo.Announcement }}</marquee>
        </div>

    </div>

    <!-- 功能点列表 -->
    <div class='bottom-part'>
        <div class="area">
            <!-- <sub-title [subTitleName]='p.menuName' *ngIf='p.children.length>0'></sub-title> -->
            <div class="area-content">
                <div class="each-module" *ngFor="let f of PList" (click)="goPage(f)">
                    <img [imgStateUrl]='"assets/imgs/gallery/SVG/"+f.icon' imgDefault="assets/imgs/gallery/SVG/17028.svg">
                    <p>{{ f.menuName }}</p>
                </div>
            </div>
            <div></div>
        </div>

        <hr style="height:8px;width:100%;background-color: #F5F5F5 !important;margin:0;" *ngIf='PList.length>0'>

        <!-- vip客户公司列表 -->
        <div class="area area-info">
            <h3 class="area-title">VIP客户</h3>
            <div class="area-content">
                <div class="each-module" *ngFor="let g of groupList" (click)="goGroupPage(g)">
                    <!-- <img [imgLazyLoad]='"assets/imgs/gallery/SVG/"+g.appLog' imageBeforeLoad='assets/imgs/gallery/SVG/17028.svg' selector='index-operation' /> -->
                    <img [imgStateUrl]='"assets/imgs/gallery/SVG/"+g.appLog' imgDefault="assets/imgs/gallery/SVG/17028.svg">
                    <p class="each-name">{{ g.companyName }}</p>
                </div>
            </div>
        </div>
    </div>
</ion-content>